<?php
require_once APPLICATION_PATH . '/modules/digCms/Exception.php';
/**
 * 
 * Digitalus2 CMS
 *
 * @package    	Digitalus\Content
 * @copyright  	Copyright (c) 2009,  Digitalus Media USA (http://digitalusmedia.net)
 * @license    	New BSD License, library/Dig/License.txt
 * @version 	2.0
 * 
 */
class DigCms_Bootstrap extends Zend_Application_Module_Bootstrap
{
    /**
     * confirm that all of the required modules are installed
     *
     */
    protected function _initDependencies()
    {
        Dig_Service_Module::exists(array(
            'digUser',
            'dig',
            'digNavigation',
            'digContent',
            'digUi'),
            true // throw an exception if the module does not exist
        );
    }

    /**
     * create the dig instance
     *
     */
    protected function _initItems()
    {
        // require the base item controller
        require_once APPLICATION_PATH . '/modules/digCms/controllers/ItemController.php';
        DigCms_Service_Item::registerItems();
    }

    protected function _initPageHead()
    {
        $front = Zend_Controller_Front::getInstance();
        $front->registerPlugin(new DigCms_Plugin_PageHead());
    }
    
}
?>